{% extends "template.html" %}

{% block conteudo %}

<form method="post" action="/Competencia/{{id}}/Incluir/" >

		{% csrf_token %}
		<div class='formulario'>
			 {{ form.competencia.label }}:{{form.verbo}}{{form.competencia}} 
			<input type=image src="{{ MEDIA_URL }}images/mais.png" width="20" height="20"> 
			{{ form.errors }}
		</div>
</form>

<form action="/Competencia/" method="post">
	{% if erro %}
		{{ erro }}
	{% endif %}
	<table border="0" id="dr" width="100%" >
		<tbody>		
			<th colspan="2">
				{{ form.competencia.label }}s
			</th>
			{% if erroLista %}
			 	<tr class="{{ classetr }}">
			 	 <td colspan="2" >
					{{ erroLista }}
					</td>
				</tr>
			{% endif %}
			{% for competencia in competencias %}
			{% cycle 'odd' 'even' as classetr silent %}        
            	<tr class="{{ classetr }}">
            		<td>
						{{ competencia.bloom }} {{ competencia.descricao }}
					</td>
					<td>
						<a href="/Competencia/{{id}}/Excluir/{{ competencia.id }}"><img src="{{ MEDIA_URL }}images/lixeira.png" width="20" height="20"/></a>
					</td>
				</tr>
			{% endfor %}
		</tbody>
	</table>
</form>
<div class='navegacao'>
	<input type="submit" value="Voltar" onclick="location. href= '/DisciplinaRelacionada/{{id}}' ">
	<input type="submit" value="Proximo" onclick="location. href= '/Habilidade/{{id}}' ">
</div>
{% endblock %}



